package com.wondertek.poms.core.filter.impl;

import com.wondertek.poms.core.filter.BaseRuleFilter;
import com.wondertek.poms.core.filter.RuleFilterChain;
import com.wondertek.poms.dao.po.Content;
import com.wondertek.poms.dao.po.IRulePo;
import com.wondertek.poms.dao.po.PrdInfoRule;


/**
 * <p><b>RecommendationFilter Description:</b> 推荐标签过滤器 </p>
 * @author douzi
 * <b>DATE</b> 2019年8月5日 下午9:46:43
 */
public class RecommendationFilter extends BaseRuleFilter {

	@Override
	public void doFilter(IRulePo rule, Content c, RuleFilterChain chain) {
		if (rule instanceof PrdInfoRule) {
			PrdInfoRule r = (PrdInfoRule) rule;
			this.manyFilter(r.getPrdRuleId(), 
					r.getRecommendation(), 
					c.getRecommendation(), 
					chain, 
					"推荐标签-Recommendation");
		}
		chain.doFilter(rule, c, chain);
	}

}
